home *** CD-ROM | disk | FTP | other *** search
/ Reverse Code Engineering RCE CD +sandman 2000 / ReverseCodeEngineeringRceCdsandman2000.iso / RCE / Library / +ORC / Orc pac 2 / FILEZ.ZIP / PERISCOP.ZIP / NOTES.TXT < prev    next >
Encoding:
Text File  |  1993-06-18  |  50.6 KB  |  1,253 lines

  1. This file contains various technical notes and tips about Periscope.
  2.  
  3.  
  4. DEBUGGING THEORY
  5. ****************
  6.  
  7. The 8086 processor family provides two built-in functions that aid
  8. the debugging process. These are the breakpoint and single-step
  9. capabilities. The 80386 and later CPUs have four debug registers that
  10. let you set limited real-time breakpoints. (See the BD command.)
  11.  
  12. The breakpoint capability uses a special single-byte code to indicate
  13. that a breakpoint is to be taken. This op code causes the system to
  14. perform an Interrupt 3 when the first byte of an instruction equals
  15. CCH. This is the facility used by the Go command in Periscope, for
  16. both the temporary and sticky code breakpoints.
  17.  
  18. When Periscope sets a code breakpoint, the original byte is saved in
  19. an internal table and a CCH is inserted in its place. For this
  20. reason, it is not possible to set a code breakpoint in ROM or other
  21. unmodifiable memory. (You can use the debug registers to set
  22. breakpoints in ROM.)
  23.  
  24. When the breakpoint is taken, Periscope is entered through a special
  25. entry point. The use of this entry point signals Periscope to
  26. decrement the instruction pointer (IP) by one to show the correct
  27. instruction. If an unexpected instruction contains a CCH in the first
  28. byte, Periscope is unable to reset the instruction to its prior value
  29. and will disassemble the instruction as INT 3.
  30.  
  31. Single-step is the other type of 8086 breakpoint. It is set by
  32. modifying the trap flag to indicate that every instruction should be
  33. trapped. If this flag is set, the system performs an Interrupt 1
  34. before the execution of each instruction, allowing you to single-step
  35. through a program. The debug register breakpoints also use INT 1.
  36.  
  37. If an instruction outside Periscope clears the trap flag, it causes
  38. any tracing currently underway to be turned off. If an instruction
  39. external to Periscope sets the trap flag unexpectedly, Periscope pops
  40. up with a 'Trap 01' message. Since the distribution version of
  41. Periscope cannot be used to trace itself, it is not possible for it
  42. to trace the execution of Interrupts 1, 2, or 3 or any other
  43. interrupts that point to Periscope. If you want to debug a program
  44. that uses these interrupts, try using the passive remote feature of
  45. Model IV!
  46.  
  47. Some programs may use Interrupts 1, 2, or 3 for their own purposes.
  48. Periscope normally refreshes these vectors each time it is activated,
  49. but you can override this vector refresh when CONFIG is run.
  50.  
  51.  
  52. NMI USE
  53. *******
  54.  
  55. All models of Periscope make use of Interrupt 2, the non-maskable
  56. interrupt (NMI). This interrupt is used by the break-out switch and
  57. Model IV to gain control of the system and enter Periscope, even if
  58. hardware interrupts are disabled.  A few systems do not support the
  59. use of NMI, since it is either not available on the system bus or is
  60. used by some other system function.
  61.  
  62. The most common use of NMI is to emulate a 6845 CRT controller on
  63. some of the nonstandard display adapters. For example, some EGAs
  64. support CGA emulation. This is achieved using software that is
  65. activated via an NMI. Luckily, the use of NMI by most of these boards
  66. can be turned off so that there is no conflict with Periscope's
  67. break-out switch. There are no reports of VGAs that use NMI for this
  68. CGA emulation.
  69.  
  70. Generally, you can load Periscope after the emulation code is loaded,
  71. or disable the emulation. If the device reasserts NMI periodically,
  72. you may have problems using the break-out switch.
  73.  
  74. If you're using EMM386.SYS or CEMM.SYS, note that these drivers do
  75. not handle INT 2 (NMI) correctly under all circumstances.  If you
  76. press the break-out switch at the wrong time, the system may hang or
  77. reboot itself. Try using another memory manager, such as 386MAX or
  78. QEMM for best results.
  79.  
  80. If an 8087 is used with interrupts enabled, an error will cause an
  81. NMI. Since Periscope uses the NMI, the debugger screen is displayed.
  82. Since the 8087 may interrupt the 8088 at any point, CS:IP may contain
  83. any value. The 80287 and later numeric processors do not use the NMI,
  84. so an error will not invoke Periscope.
  85.  
  86. If you're loading Periscope at CONFIG.SYS time with SYSLOAD.SYS, note
  87. that DOS may corrupt the NMI vector after Periscope is loaded, but 
  88. before the DOS prompt is displayed. To stop this corruption, use the
  89. directive 'STACKS=0,0' in CONFIG.SYS.
  90.  
  91.  
  92. CPU DIFFERENCES
  93. ***************
  94.  
  95. Many PCs and XTs have an early version of the 8088 CPU that has a
  96. serious bug.  This version can be identified by the copyright date of
  97. 1978 shown on the chip. The defect in these CPUs is that the
  98. instruction after an instruction that changes the stack segment is
  99. not protected from being interrupted. The defined method for changing
  100. the stack is to change the stack segment and then immediately change
  101. the stack pointer. If this process is interrupted, the stack may be
  102. in no man's land, the beginning of a system hang. The fix is to get
  103. the later chip, identified by copyright dates of 1978 and 1981. At
  104. install time, Periscope checks for a defective 8088. If one is found,
  105. an error is displayed.
  106.  
  107. On a correctly functioning 8088, any instruction that modifies any of
  108. the segment registers protects the next instruction from being
  109. interrupted. This is a bit of overkill, since changes to DS, ES, and
  110. CS do not need the protection that stack changes require. This is why
  111. you'll notice that Periscope skips instructions while tracing through
  112. an instruction that modifies a segment register. The instruction was
  113. actually executed, but it was invisible to Periscope. Be careful not
  114. to use Periscope's Go command to stop in the middle of a stack change
  115. over, since this can cause the same problem as the defective 8088.
  116.  
  117. The NEC V20 and the 80C88 go even further than the 8088. They also
  118. protect the instruction after a read of the segment registers, except
  119. for POP instructions. For example, the V20 protects the instruction
  120. after MOV AX,ES, while the 8088 does not.
  121.  
  122. On the 80286 and later CPUs, the instruction protection for changes
  123. to segment registers applies only to the stack segment. Instructions
  124. that change DS, ES, or CS do not protect the next instruction. Still,
  125. be careful not to use the Go command to stop in the middle of a stack
  126. change.
  127.  
  128. For the 80286 and later CPUs, Periscope may be used in real or
  129. virtual 8086 mode. The trap (or exception interrupt) 6 (invalid op
  130. code) and 0DH (segment overrun) are intercepted by Periscope with
  131. CS:IP pointing to the offending instruction.  (You may configure
  132. Periscope not to intercept these exception interrupts.) If the code
  133. segment of these interrupts points to memory below PS.COM when it is
  134. installed, no change is made to the interrupt since it is already in
  135. use.  Avoid use of hardware interrupt IRQ 5 (INT 0DH) on an AT for
  136. such things as a mouse, since a segment overrun that occurs when this
  137. interrupt does not point to Periscope will hang your system. If you
  138. get an exception interrupt, chances are good that the system is
  139. severely corrupted. A reboot is generally recommended.
  140.  
  141.  
  142. DOS NOTES
  143. *********
  144.  
  145. Under some versions of DOS (e.g., 3.10), DOS decides whether a
  146. program is an EXE based on the first two bytes in the file, not the
  147. file extension. This can cause problems with RUN.COM, since it
  148. assumes that a file with a .COM extension is really a COM file. If
  149. the extension is .EXE, RUN confirms that the first two bytes indicate
  150. an EXE file.
  151.  
  152. If you're using MS DOS 3.20 and are loading PS as a device driver, note
  153. that DOS modifies INT 2 (NMI) after CONFIG.SYS time. To prevent the
  154. modification of INT 2, patch IBMBIO.COM at offset B0DH.
  155.  
  156. So that Periscope can perform file I/O safely, it checks the
  157. undocumented in-DOS flag. This byte contains zero if DOS is not busy.
  158. Periscope also checks to see that interrupts are enabled, to be sure
  159. that DOS was interrupted at a safe point. The location of the in-DOS
  160. flag can be found by performing INT 21H with AH=34H. ES:BX returns
  161. the address of the flag.
  162.  
  163. If you want to perform file I/O and Periscope is telling you that DOS
  164. is busy, get CS:IP back to your code and try again. Do not attempt to
  165. modify the in-DOS flag or the interrupt flag in order to fool
  166. Periscope. You can get a garbled disk directory very easily. To make
  167. DOS not busy, you can use the user breakpoint in the sample program
  168. USEREXIT.ASM. Periscope also allows file I/O when CS:IP is at the
  169. entry to INT 28H. To get to INT 28, enter G {0:28*4}. Periscope does
  170. not hook INT 28, but uses it as a known safe point to perform DOS
  171. access.
  172.  
  173. Starting with DOS 3.20, Interrupts 1, 2, and 3 are changed by DOS on
  174. a short boot. This can complicate matters if you're trying to use the
  175. break-out switch across a short boot. You'll need to patch DOS or
  176. better yet, reset the vectors to point to Periscope. Also, you can
  177. copy INT 2 to INT 5 (Shift-PrtSc) by entering the command M 0:2*4 L4
  178. 0:5*4. After this has been done, you can use Shift-PrtSc as a method
  179. of activating Periscope.
  180.  
  181. For DOS 3.20 and later, you can patch DOS so that it won't revector
  182. INT 3.  Search for 83 C7 04 93 AB 93 AB in IO.SYS or IBMBIO.COM and
  183. change this sequence to 83 C7 08 90 90 90 90. This reportedly works
  184. in all versions of MS and PC DOS from 3.20 to 5.00. Note: this is at
  185. offset 1EF6 in MS-DOS 5.00.
  186.  
  187. Compaq DOS 3.31, Rev E corrupts interrupt 0dh, which is used by 
  188. Periscope to indicate a segment wrap-around exception.
  189.  
  190.  
  191. DEBUGGING TECHNIQUES
  192. ********************
  193.  
  194. While Periscope is active, the BIOS interrupt vectors it uses are
  195. reset to point to BIOS unless the corresponding /V installation
  196. option was used. To access some memory-resident programs while
  197. Periscope is active, you may have to use some of these options. For
  198. example, a program that displays the time may use interrupt 1CH.
  199. Unless you specify /V:1C when PS.COM is run, the clock program won't
  200. be active when Periscope is. Be aware that each /V option used
  201. reduces Periscope's dependability, since the interrupt vector is left
  202. pointing to RAM that can be corrupted. If you're having problems
  203. running some software with Periscope, check the interrupt vectors
  204. using INT.COM.
  205.  
  206. Avoid debugging with ill-behaved resident programs in the system.
  207. While you can debug with these types of programs in the system, they
  208. can often muddy the waters, making it much harder for you to see just
  209. what your program is doing.
  210.  
  211. When you press the break-out switch to stop the execution of a
  212. program, chances are very good that you'll stop the machine in either
  213. BIOS or DOS. If you want to get back to your program, use the Go
  214. command to execute to a known point in your program. You can also use
  215. the SR command to look for return points on the stack. If that's not
  216. possible, try using the Register breakpoint. Enter BA * to clear any
  217. breakpoints currently set. If you know your program's Code Segment,
  218. enter BR CS EQ nnnn to set a Register breakpoint when CS equals the
  219. desired value. If you aren't sure, use BR CS NE CS to set a
  220. breakpoint when the Code Segment changes from its current value. Then
  221. enter GT to continue execution with the Register breakpoint set. This
  222. will usually get you back to the program, or at least from BIOS to
  223. DOS or vice-versa. If you're debugging a program that has line
  224. numbers as symbols, enter TL or JL to get back to your code.
  225.  
  226. Microsoft and Borland compilers can place data (pseudo-code) after
  227. interrupts 34H through 3DH to emulate the 8087 numeric processor.
  228. When disassembled by Periscope, the data following the interrupt
  229. causes the disassembly to be garbled. To prevent execution of data,
  230. the Jump command traces interrupts in the range from 34H to 3DH.
  231.  
  232. If you're calling assembly-language subroutines from a high-level
  233. language, Periscope can be used to trace through the execution of the
  234. subroutine to verify that it is operating correctly. If the
  235. subroutine is linked to a compiled program, simply use G SUBNAME,
  236. where SUBNAME is the name of the subroutine. If the subroutine is
  237. being called from an interpretive language such as BASIC, modify the
  238. subroutine so that the first byte contains CCH.  Then when the
  239. subroutine is executed, the breakpoint (CCH) will activate Periscope.
  240. At that point, you can modify the instruction to be a NOP (no
  241. operation) by using E CS:IP 90 or skip to the next instruction by
  242. using R+.
  243.  
  244. Avoid debugging packed EXE files. You'll have to trace through the
  245. header before your program is unpacked and available. If you must
  246. debug a packed EXE, use RUN to load the program, use the G command to
  247. start execution, press the break-out switch, and then start
  248. debugging.
  249.  
  250. If you're tracing the system BIOS, try using a system such as the
  251. Compaq Deskpro 386, which shadows ROM at segment F000 into RAM. When
  252. shadowed memory is used, you can use all the usual commands to trace
  253. through the BIOS.
  254.  
  255. If you're debugging an INT 21H handler, use the '/A' command to turn 
  256. Periscope's use of DOS services off. This will keep Periscope from
  257. trying to use DOS and thus re-enter your INT 21H handler while you're
  258. tracing through it.
  259.  
  260.  
  261. PERISCOPE INTERNALS
  262. *******************
  263.  
  264. Periscope uses Interrupts 1 (single-step), 2 (NMI), and 3
  265. (breakpoint). In an 80286 or later CPU system, Periscope may also
  266. intercept Interrupts 6 (invalid op code) and DH (segment wraparound).
  267.  
  268. The data fields used by Periscope are located at the beginning of the
  269. protected memory. The record definition PSDATA in the file PS.DEF
  270. contains the most useful of these data fields. The source file
  271. contains comments describing the various fields in the record
  272. definition. To display Periscope's data area assuming the default
  273. memory address of D000:0000, enter DR D000:100 PSDATA.
  274.  
  275. Note:  When Periscope is loaded into DOS memory, enter DR xxxx:100
  276. PSDATA, where xxxx is the starting segment for Periscope's tables.
  277. (The segment used by INT 3.)
  278.  
  279.  
  280. THE PERISCOPE MODEL I (PLUS) BOARD
  281. **********************************
  282.  
  283. There are four major revisions of the Model I board.
  284.  
  285. 1. Rev 1 is the original 16K board. It is a half-length card with
  286. eight 2K by 8 static RAM chips across the top. The last version of
  287. the Periscope software that supported this board was 2.10. The board
  288. has not been produced since mid-1986.
  289.  
  290. 2. Rev 2 is the 56K board. It is a half-length card with seven 8K by
  291. 8 static RAM chips across the top. The last version of the Periscope
  292. software that supported this board was 4.21. Production of this board
  293. ceased in mid-1988.
  294.  
  295. 3. Model I/MC, Rev 1 is the version of the Model I board for MCA
  296. (PS/2) systems. It is functionally the same as the Model I, Rev 3A
  297. board, except that it has no DIP switches and has a capacity of up to
  298. 2048KB. It uses 256KX4 RAM chips and is supported starting with
  299. Periscope software version 4.30. Production of this board ceased in
  300. mid-1992.
  301.  
  302. 4. Rev 3A is the currently-produced 512K/1024K board. It is a
  303. full-length card with sixteen or thirty-two 256K by 1 dynamic RAM
  304. chips. It is supported starting with Periscope software version 4.10.
  305. This board runs on ISA and EISA systems.
  306.  
  307. The Model I board uses a 32K memory footprint and two consecutive I/O
  308. ports. The board can run with either 16 or 32 chips of 256K-by-1
  309. dynamic RAM, with a cycle time of 150 NS or less. The capacity is
  310. 512K or 1 Megabyte, respectively. The starting address of the memory
  311. is switch-selectable to any of eight locations. The starting I/O port
  312. is switch-selectable to any four-byte boundary. The board can be used
  313. by itself (as a Model I) or with a Model IV board (as a "Plus"
  314. board). It draws 9 watts of power when populated with 512K; 14 watts
  315. when populated with a full megabyte.  To program the board, see the
  316. description below.
  317.  
  318. If you're using Periscope I, Rev 3 on an AT&T 6386 WGS that has an
  319. Olivetti (not Intel) motherboard, you'll find that Periscope doesn't
  320. run correctly. This is because Olivetti does not provide a refresh
  321. signal for dynamic RAM in non-Olivetti cards. There is a software
  322. solution -- call tech support and request a copy of REFRESH.COM.
  323.  
  324. The Model I, Rev 3 board has a 32K footprint, with four 8K banks. To
  325. program the board, use an OUT 300,DBH to enable writes to the board
  326. and select bank 3 (the last 8K). Each OUT 300,FBH decrements the
  327. current bank (3, 2, 1, then 0). An out of value other than DBH or FBH
  328. to port 300H protects the board.
  329.  
  330. To select the page for a bank, do an OUT 301,nn, where nn is the page
  331. number from 0 to 3FH if a 512K board is used (7FH for 1024K and FFH
  332. for 2048K).
  333.  
  334. For example, to set bank 3 to page 1FH, bank 2 to page 1EH, bank 1 to
  335. page 1DH, and bank 0 to page 1CH, do the following:
  336.  
  337.     out 300,db    ; enable the board and select bank 3
  338.     out 301,1f    ; set bank 3 to page 1f
  339.     out 300,fb    ; select bank 2
  340.     out 301,1e    ; set bank 2 to page 1e
  341.     out 300,fb    ; select bank 1
  342.     out 301,1d    ; set bank 1 to page 1d
  343.     out 300,fb    ; select bank 0
  344.     out 301,1c    ; set bank0 to page 1c
  345.     out 300,0    ; protect the board
  346.  
  347. - You can skip a bank setting -- just skip the OUT 301,nn as needed.
  348.  
  349. - You can have one page active in multiple banks.
  350.  
  351. - You can change the page for the current bank by issuing another OUT
  352. 301,nn.
  353.  
  354. The Model I board can be set to run in either 8 or 16-bit mode. Due
  355. to the design of the PC bus, all devices within the same 128K region
  356. of memory (such as C000:0 to D000:FFFF) should theoretically all be
  357. running as either 8-bit or 16-bit devices. In practice, this
  358. condition is not often encountered, but be aware that you may have to
  359. change the mode of operation for the Model I board due to other cards
  360. that share the same 128K address space.
  361.  
  362.  
  363. THE PERISCOPE MODEL IV BOARD
  364. ****************************
  365.  
  366. There are two revisions of the Model IV board. Rev 1 is the original
  367. Model IV board. It has a 2K deep trace buffer and runs at CPU speeds
  368. of up to 25 MHz. Model IV, Rev 2 has a 16K deep trace buffer and runs
  369. at CPU speeds of up to 33 MHz. It supports the 80286, 80386SX,
  370. 80386DX, and 80486DX CPUs (including the DX2 chips up to 66 MHz. 
  371.  
  372. The Periscope IV boards use no memory and eight consecutive I/O
  373. ports.  The starting I/O port is switch-selectable to any eight-byte
  374. boundary. The board draws approximately 20 watts of power, and the
  375. pods draw approximately 3 watts of power. If you're interested in
  376. programming information on Model IV, please call Tech Support.
  377.  
  378.  
  379. FUNCTION KEY ASSIGNMENT
  380. ***********************
  381.  
  382. Periscope's function keys are user-assignable. The files CVKEYS.PSD,
  383. PSKEYS.PSD, and CVKEYS.PSD are used to emulate the function keys used
  384. by Microsoft's CodeView, Periscope, and Borland's Turbo Debugger
  385. respectively. The .DEF files used to create these .PSD files are
  386. shown below. Note the FX alias definition is used to display the
  387. function key use when the menu system is enabled but not active.
  388.  
  389. The resulting PSD file must be 511 characters or less to fit into the
  390. read-only buffer. No record definitions are allowed in this buffer,
  391. just alias definitions. The .PSD file is read at PS.COM time.  If an
  392. error occurs reading CVKEYS.PSD or TDKEYS.PSD, error 75 is displayed,
  393. but an error reading PSKEYS.PSD is ignored. When displaying or using
  394. alias definitions, Periscope uses the read-only area first, then uses
  395. the standard record definition buffer. The LD and WD commands affect
  396. the record definition buffer only -- they have no effect on the
  397. read-only buffer. 
  398.  
  399. CVKEYS.DEF
  400. \fx=F4:Screen  F5:Go  F7:Go Here  F8:Trace  F9:Break Here  F10:Step
  401. \f1=?;
  402. \f2=!ar;
  403. \f3=* Key not assigned for CV;
  404. \f4=!ao;
  405. \f5=g;
  406. \f6=!aw;
  407. \f7=g cs:ip;
  408. \f8=tl;
  409. \f9=!cb;
  410. \f0=jl;
  411.  
  412. PSKEYS.DEF
  413. \fx=F1:Timing  F2:Swap  F3:Prev  F4:Repeat  F8:Symbols  F10:Screen
  414.  
  415. TDKEYS.DEF
  416. \fx=F2:Break at Top  F4:Go Here  F6:Next  F7:Trace  F8:Step  F9:Go  
  417. \f1=?;
  418. \f2=!cb;
  419. \f3=/w ?;
  420. \f4=g cs:ip;
  421. \f5=* Key not assigned for TD;
  422. \f6=!aw;
  423. \f7=tl;
  424. \f8=jl;
  425. \f9=g;
  426. \f0=!am;
  427.  
  428.  
  429. REMOVING PERISCOPE FROM MEMORY
  430. ******************************
  431.  
  432. If you're using a Model I, Rev 3 or I/MC board, the Periscope
  433. software always loads into the board without using any DOS memory, so
  434. the following section does not apply to you. If you're using the
  435. Periscope/EM software, Periscope loads into the protected memory
  436. provided by 386MAX, QEMM, or Netroom without using any DOS memory, so
  437. the following section does not apply to you.
  438.  
  439. Don't both remove Periscope from DOS memory and reload it within the
  440. same batch file. The batch header gets in the way and causes the new
  441. copy of Periscope to be loaded too high in memory. For example, if
  442. you need to remove the current copy of Periscope from memory and
  443. install a new copy, enter 'PS/Y' then load the new copy.
  444.  
  445. You can also use one batch file containing the lines 'PS/Y' and 'X',
  446. where X is the name of a second batch file that is used to reload
  447. Periscope. This technique causes the batch header to be relocated
  448. downward when chaining from the first batch file to the second.
  449.  
  450.  
  451. TRAPS (AKA EXCEPTION INTERRUPTS)
  452. ********************************
  453.  
  454. If you're having problems with your program executing out of non-code
  455. locations, fill all memory not used by your program (or DOS) with
  456. ff's to cause an exception interrupt when executed.
  457.  
  458. If you're using 386MAX with Periscope and want it to pass exception
  459. interrupts along to Periscope, add the statement 'debug=inv' or
  460. 'debug=sor' to your 386MAX invocation line in CONFIG.SYS. The first
  461. statement uses exception interrupt 6 to activate PS and the second
  462. form uses interrupt 0dh.
  463.  
  464.  
  465. DIVIDE BY ZERO
  466. **************
  467.  
  468. If you're getting divide faults, enter 'm 0:8 l4 0:0' to copy INT 2
  469. over INT 0 (the divide overflow vector). When a divide overflow
  470. occurs, Periscope's screen will be displayed. If you're debugging a C
  471. program, be sure to go to _MAIN before copying the vector, since the
  472. prologue resets INT 0 to point to the divide by zero handler in your
  473. program.
  474.  
  475.  
  476. CONFIG.COM
  477. **********
  478.  
  479. CONFIG.COM makes Periscope dynamically configure itself when PS.COM
  480. is run.  If you have problems, try booting the system without
  481. CONFIG.SYS or AUTOEXEC.BAT and then use 'CONFIG 1' to force the
  482. dynamic configuration to occur at CONFIG.COM time instead of when
  483. PS.COM is loaded.  If that doesn't work, try using 'CONFIG 2' to
  484. force the old-style configuration. If either of these methods are
  485. used, you'll need to reconfigure Periscope when any hardware change
  486. is made to the system.
  487.  
  488. If you're using Borland's Superkey program, you can use the new
  489. dynamic configuration as long as Periscope is loaded before Superkey,
  490. since it does some nasty tricks with interrupt vectors.  If you want
  491. to be able to load Periscope after Superkey, use the '1' or '2'
  492. options described above.
  493.  
  494. Periscope's dynamic configuration works well in the vast majority of
  495. situations. However, if you have a device driver or TSR that hooks an
  496. interrupt of interest to Periscope (8, 9, 10h, 15h, 16h, 17h, or
  497. 1Ch), but does not pass the interrupt on to the previous interrupt
  498. handler, you must load PS.COM before the driver or TSR in question. 
  499.  
  500.  
  501. SETTING 43-LINE OR 50-LINE MODE
  502. *******************************
  503.  
  504. To set your EGA in 43-line mode or your VGA in 50-line mode, use the
  505. following code:
  506.  
  507.     mov    ax,0003
  508.     int    10h
  509.     mov    ax,1112h
  510.     mov    bl,00
  511.     int    10h
  512.     xor    ax,ax
  513.     mov    es,ax
  514.     mov    ax,0100h
  515.     mov    cx,0607h
  516.     or    byte ptr es:[0487h],01
  517.     int    10h
  518.     and    byte ptr es:[0487h],0feh
  519.     int    20h
  520.  
  521.  
  522. PUBLIC.COM
  523. **********
  524.  
  525. PUBLIC has been dropped from the Periscope package and placed into
  526. the public domain. If you'd like a copy of it (including ASM source
  527. code), please send a SASD (self-addressed stamped disk) to us at the
  528. address in the front of the manual. If you are outside the USA,
  529. please send just an international postal coupon for US $5.00 to cover
  530. the cost of a disk and postage. You can also download it from our
  531. BBS.
  532.  
  533.  
  534. COMMON I/O PORT USAGE
  535. *********************
  536.  
  537. The following is a list of common I/O port usage.
  538.  
  539. I/O address    Description
  540.  
  541. 0000h-0019h    DMA 
  542. 0020h-003Fh    8259 Programmable interrupt controller (PIC)
  543. 0040h-005Fh    Programmable interval timer
  544. 0060h        Keyboard data input/output buffer
  545. 0061h        8255 output (XT only), 8042 control register (AT only)
  546. 0062h        8255 input (XT only)
  547. 0063h        8255 command mode register (XT only)
  548. 0064h        8042 keyboard input buffer (AT only)
  549. 0065h-006Fh    reserved by 8255 (XT only) or 8042 (AT only)
  550. 0070h        CMOS RAM address register (AT only)
  551. 0071h        CMOS RAM data register (AT only)
  552. 0080h        Manufacturing test port (AT only)
  553. 0081h-009Fh    DMA 
  554. 00A0h        NMI mask (XT), Programmable interrupt controller 2
  555. 00A1h        Programmable interrupt controller 2 mask
  556. 00C0h-00DEh    DMA 
  557. 00DFh-00EFh    Reserved
  558. 00F0h-00FFh    Math coprocessor
  559. 0100h-016Fh    Reserved
  560. 0170h-0177h    Fixed disk 1 (AT only)
  561. 01F0h-01F7h    Fixed disk 0 (AT only)
  562. 01F9h-01FFh    Reserved
  563. 0200h-020Fh    Game control port
  564. 0210h-0217h    Expansion unit (PC and XT only)
  565. 0278h-027Ah    Parallel 3
  566. 02B0h-02DFh    Reserved
  567. 02E1h        GPIB (adapter 0)
  568. 02E2h-02E3h    Data acquisition (adapter 0)
  569. 02E4h-02F7h    Reserved
  570. 02F8h-02FFh    Serial 2
  571. 0300h-031Fh    Prototype card
  572. 0320h-0324h    Fixed disk adapter 
  573. 0325h-0347h    Reserved
  574. 0348h-0357h    DCA 3278
  575. 0360h-036Fh    PC network (PC and XT only)
  576. 0372h-0377h    Diskette controller
  577. 0378h-037Ah    Parallel 2
  578. 0380h-038Fh    SDLC and BSC communications
  579. 0390h-0393h    Cluster (adapter 0)
  580. 03A0h-03AFh    BSC communications (primary)
  581. 03B0h-03DFh    Video - MDA, CGA, EGA, and VGA
  582. 03F0h-03F7h    Diskette controller
  583. 03F8h-03FFh    Serial 1
  584.  
  585.  
  586. PERISCOPE'S FILES
  587. *****************
  588.  
  589. The following files may be present on the Periscope distribution disk
  590. or in the Periscope directory:
  591.  
  592. CLEARNMI.COM - Despite the name, the non-maskable interrupt (NMI)
  593. used by the break-out switch can be masked out. This memory-resident
  594. utility program attaches to the timer interrupt and clears the
  595. non-maskable interrupt as needed.
  596.  
  597. CONFIG.COM - This utility program is used to configure the Periscope
  598. software, moving it from the distribution disk onto your working
  599. disk. 
  600.  
  601. CVKEYS.PSD - This record definition file contains the aliases used
  602. for CodeView function key emulation.
  603.  
  604. FTOC.C - This is the source for the Fahrenheit-to-Celsius program
  605. from the Kernighan and Ritchie text. This program is used in the C
  606. tutorial.
  607.  
  608. FTOC.DEF - This is a Periscope record definition file used when
  609. debugging the FTOC program.
  610.  
  611. FTOC.EXE - This is the executable code for the FTOC program.
  612.  
  613. FTOC.MAP - This is the MAP file produced by the linker for the FTOC
  614. program. It contains symbol and line number references. 
  615.  
  616. INT.COM - This utility program is used to save, display, or compare
  617. the values of the interrupt vectors. It is typically used to
  618. determine the interrupt vectors used by a resident program.
  619.  
  620. NOTES.TXT - This file contains miscellaneous technical notes not
  621. included in the manual.
  622.  
  623. PERI.PGM - This is the self-extracting file that contains most of the
  624. other files in this list. This file is on the distribution disk only.
  625.  
  626. PM1.COM - This is the code for the menu system for Models I, II, and
  627. Periscope/EM.
  628.  
  629. PM4.COM - This is the code for the menu system for Model IV. 
  630.  
  631. PO1.COM - This is overlay code used by Periscope/32.
  632.  
  633. PS.COM - This is the transient loader portion of Periscope.  It is
  634. used to load the PS1.COM file created by the configuration program,
  635. CONFIG.COM.
  636.  
  637. PS.DEF - This ASCII text file contains some sample Periscope record
  638. definitions that are read when RUN.COM is used to load a program. 
  639.  
  640. PS1.COM - This is the configured form of PS2.COM.
  641.  
  642. PS2.COM - This is the unconfigured form of the Periscope program for
  643. all models. It is converted to PS1.COM by CONFIG.COM. It can be used
  644. only via PS.COM.  
  645.  
  646. PS4.COM - This is the additional code for Model IV. It can be used
  647. only via PS.COM. 
  648.  
  649. PS4TEST.EXE - This program is used to run trace buffer and breakpoint
  650. tests on the Periscope IV board. 
  651.  
  652. PSHELP.TXT - This is the final Periscope help file created by 
  653. CONFIG.COM.
  654.  
  655. PSHELP2.TXT - This is the basic Periscope help file used by
  656. CONFIG.COM in creating PSHELP.TXT for all models of Periscope.
  657.  
  658. PSHELP4.TXT - This is the Periscope help file used by CONFIG.COM in
  659. creating PSHELP.TXT for Model IV. 
  660.  
  661. PSINT.DAT - This is the compiled form of the interrupt comments that
  662. is loaded into RAM when the /H installation option is used or when
  663. the menu system is enabled.
  664.  
  665. PSINT.TXT - This is the optional interrupt comments file that is
  666. compiled into PSINT.DAT by CONFIG.COM.  This file is a normal ASCII
  667. text file which can be modified as needed using a text editor. 
  668.  
  669. PSKEY.COM - This memory-resident utility program is used to select
  670. hot keys to activate Periscope via the keyboard, including SysReq,
  671. Shift-PrtSc, and other shift key combinations.
  672.  
  673. PSKEYS.PSD - This record definition file contains the aliases used
  674. for Periscope function key use.
  675.  
  676. PSTERM.COM - This program is used on another PC to support the use of
  677. the /AV (alternate video) and/or /AK (alternate keyboard)
  678. installation options.
  679.  
  680. PSTEST.COM - This program is used to run memory diagnostics on the
  681. Periscope I board.
  682.  
  683. README.TXT - This file documents any changes made to Periscope since
  684. the manual was last printed.
  685.  
  686. RS.COM - This utility program is used to verify a record definition
  687. (DEF) file and determine the record table size required by the DEF
  688. file.
  689.  
  690. RUN.COM - This is Periscope's program loader. It is used to load a
  691. program or data file into memory, read the program's symbol table and
  692. record definition table if available, and pass control to Periscope. 
  693.  
  694. SAMPLE.ASM - This is the source code for the sample assembler program
  695. used in the tutorial.  
  696.  
  697. SAMPLE.COM - This is the executable code for the SAMPLE program.
  698.  
  699. SAMPLE.MAP - This is the MAP file produced when the SAMPLE program is
  700. linked. 
  701.  
  702. SETUP.COM - This program is used to copy the Periscope files from the
  703. distribution disk to the target directory. This file is on the
  704. distribution disk only.
  705.  
  706. SKIP21.COM - This program enables Model IV users to watch for writes
  707. to low memory in real-time, at the same time filtering out writes
  708. that are legitimately done by DOS. 
  709.  
  710. SYMLOAD.COM - This utility program lets your program change
  711. Periscope's symbol table while your program is running. It is useful
  712. for programs that manage their own overlays or are running under
  713. another environment.
  714.  
  715. SYSLOAD.SYS - This utility program is used to load any COM file as a
  716. device driver. It can be used to load Periscope at CONFIG.SYS time,
  717. allowing you to debug device drivers. 
  718.  
  719. TDKEYS.PSD - This record definition file contains the aliases used
  720. for Turbo Debugger function key emulation.
  721.  
  722. TS.COM - This utility program is used to verify a MAP file or other
  723. source of symbols and determine the symbol table size required. It is
  724. used to generate a Periscope symbol (PSS) file. 
  725.  
  726. USEREXIT.ASM - This sample program illustrates user breakpoints and
  727. user exits from Periscope. 
  728.  
  729. USEREXIT.COM - This is the executable code generated from
  730. USEREXIT.ASM.
  731.  
  732. WAITING.COM - This program can be used to keep DOS available when
  733. debugging TSRs.
  734.  
  735. The minimum set of files required on the target directory is PS.COM,
  736. PS1.COM, and RUN.COM. For function key emulation, you'll need
  737. CVKEYS.PSD or TDKEYS.PSD. For Model IV, you'll also need PS4.COM. For
  738. the menu system, you'll need PSHELP.TXT and PMx.COM, where x is 4 or
  739. 1 for Model IV and all others respectively. 
  740.  
  741.  
  742. NULL-MODEM CABLE SPECIFICATIONS
  743. *******************************
  744.  
  745. If you're using Periscope/Remote or the alternate-PC feature of
  746. Periscope and would like to make your own null-modem cable, the
  747. specifications are as follows. 
  748.  
  749. The transmit and receive lines must be crossed and the CTS and RTS
  750. lines must also be crossed. Ground must carry through.
  751.  
  752. For a DB-9 connector, pin 2 (Receive) must cross to pin 3 (Transmit);
  753. pin 5 (Ground) must carry through; and pin 7 (RTS) must cross to pin
  754. 8 (CTS).
  755.  
  756. For a DB-25 connector, pin 2 (Transmit) must cross to pin 3
  757. (Receive), pin 4 (RTS) must cross to pin 5 (CTS), and pin 7 (Ground)
  758. must carry through.
  759.  
  760. See the description of the cable testing program, PSTERM in the
  761. manual.
  762.  
  763.  
  764. COLOR ATTRIBUTE BITS
  765. ********************
  766.  
  767. The /C installation option and the /C command are used to set
  768. Periscope's screen color. The value used for the color attribute is
  769. derived as follows:
  770.  
  771.          Bit number: 7    6    5    4    3    2    1    0
  772.  
  773.          Use:        X    R    G    B    H    R    G    B
  774.                           -----------         -----------
  775.                            background         foreground
  776.                              color              color
  777.  
  778.      X - blink if 1, else no blink
  779.      R - red gun on if 1, else off
  780.      G - green gun on if 1, else off
  781.      B - blue gun on if 1, else off
  782.      H - high-intensity if 1, else normal
  783.  
  784.      The RGB combinations are:
  785.      -------------------------
  786.  
  787.      Green plus Blue is Cyan
  788.      Red plus Blue is Magenta
  789.      Red plus Green is Brown (Yellow if high intensity)
  790.      Red plus Green plus Blue is Gray (White if high intensity)
  791.  
  792.  
  793. BS16 MEMORY      
  794. ************
  795.  
  796. The 80386 and 80486 CPUs can be connected to both 16-bit and 32-bit
  797. data buses.  For performance reasons, most systems use 32-bit memory
  798. for all address ranges. Some systems use 16-bit memory in the ROM
  799. region (A000:0 to E000:FFFF). When this occurs, Periscope displays a
  800. warning message when PS.COM is run, notifying you of these BS16
  801. memory segments. In many cases, the use of BS16 memory in this range
  802. actually improves performance, since most devices (including the
  803. Periscope I board) that are addressed in this range are 16-bit
  804. devices. 
  805.  
  806. When BS16 memory is present, setting data breakpoints with Model IV
  807. gets difficult. There's no problem setting address breakpoints,
  808. however.  The data always 'appears' to come in on the low 16 bits of
  809. the bus, but may also be duplicated on the high part of the bus.
  810. Since there is no 1:1 correspondence of the 80386 byte enable signals
  811. to the real data values, data breakpoints on BS16 memory can get very
  812. tricky and are best avoided.
  813.  
  814. For more information on this topic, see the Intel hardware manuals.
  815.  
  816.  
  817. TRACKING PROGRAM FLOW WITH MODEL IV
  818. ***********************************  
  819.  
  820. If you're debugging a complex task and need to get a high-level
  821. overview of the program's flow, try embedding writes to a dummy
  822. memory location or I/O port of unique values that indicate where you
  823. are in the program.  Then set the Model IV board to selectively
  824. capture writes to the memory or I/O port that you've used. Using this
  825. technique, you can more readily track the flow of the program. Also,
  826. if you want to set a breakpoint on the execution of a particular
  827. location, you can set a hardware breakpoint on the write of the
  828. memory or port, qualified by the unique data value written at that
  829. location.
  830.  
  831. For example, assume we're using a dummy I/O port of F310 and
  832. outputting values ranging from 0 to 3F at various points in the
  833. program. To capture the next 100H outs to that port and nothing else,
  834. use the following commands:
  835.  
  836.     HA *     
  837.     HC #100 S+
  838.     HP F310 O
  839.     GH
  840.  
  841. To capture the location where the value 30H is being written to the
  842. port in the center of the trace buffer, use the following commands:
  843.  
  844.     HA *
  845.     HC TC
  846.     HP F310 O
  847.     HD LB 30 30
  848.     GH
  849.  
  850.  
  851. USING THE MODEL IV TRACE BUFFER AFTER A CRASH
  852. **********************************************
  853.  
  854. If you're debugging a program that crashes the system, you'll find
  855. that in many cases a trap (or exception interrupt) will activate
  856. Periscope.  From there, you can look in the real-time trace buffer to
  857. see what lead up to the exception. In some cases, the system may have
  858. executed meaningless, but legal instructions for the full depth of
  859. the buffer, leaving you with nothing to indicate where things went
  860. awry. If this happens, try filling unused memory with FF's which will
  861. cause an trap 6 when executed, or try setting a hardware breakpoint
  862. on an event you see near the top of the trace buffer.
  863.  
  864. If the system is so far gone that Periscope can't come up, all is not
  865. lost. Install the Model IV on a system that has a reset switch. Then
  866. after the crash, do the following:
  867.  
  868. - Press the break-out switch to stop the trace buffer (it will also
  869. be stopped by reaching a hardware breakpoint).
  870.  
  871. - Press the reset switch to reboot the system without turning the   
  872. power off.
  873.  
  874. - While the system is booting, press the Alt and Ctrl keys to keep
  875. PS.COM from reloading and destroying the state of the trace buffer.
  876.  
  877. - Run 'PS4TEST/W' to save the trace buffer to the file PSBUF.DAT.
  878.  
  879. - Load Periscope normally and use the 'HT CS PSBUF.DAT' command to
  880. view the saved trace buffer.
  881.  
  882.  
  883. USING MODEL IV TO DEBUG THE POWER-ON STARTUP TESTS (POST)
  884. *********************************************************
  885.  
  886. To debug the POST sequence using Model IV, set it up for Passive
  887. remote mode (see the manual) and then do the following:
  888.  
  889. - Boot both systems and install PS.COM on the host.
  890.  
  891. - Enter HM FFFF:0 L1 X;GH to set a breakpoint on a fetch of the last
  892. paragraph in the first megabyte.
  893.  
  894. - Do a long boot on the target system using Periscope's QL command or
  895. use a reset switch to reset the machine.
  896.  
  897. - If the above doesn't work, try using 'HP 80 O;GH' instead, since
  898. your system may map the reset point to a physical address other than
  899. FFFF:0.  Port 80h is the manufacturing test port that is written to
  900. during POST.
  901.  
  902.  
  903. USING MODEL IV TO CAPTURE EVERYTHING THAT OCCURS FROM ONE POINT TO ANOTHER
  904. **************************************************************************
  905.  
  906. In many situations, you may want to capture everything that occurs
  907. from one point in your program to another, but not capture anything
  908. that occurs as a result of any other code execution. The easiest way
  909. to do this is to embed a unique event at the beginning and end of the
  910. code stream to be monitored. Use of a dummy I/O port read is both
  911. easily added to the code and guaranteed (assuming you choose a good
  912. I/O port) to be unique. Note that code fetch is not a good choice
  913. because of the prefetch problem.
  914.  
  915. You can set up hardware breakpoints to change from state 0 to state 1
  916. at the beginning of the code stream and change from state 1 to state
  917. 0 at the end of the code stream. Then set the hardware controls so
  918. that nothing is captured in the hardware trace buffer while in state
  919. 0 and issue the GH command to start execution. You'll have to
  920. manually stop Periscope, using the break-out switch or hotkeys, but
  921. nothing except the desired code stream (and its I/O and memory
  922. activity) will be captured in the trace buffer.
  923.  
  924. For example, assume you want to capture execution from point A to
  925. point B in your code and that you have an in from port 1234h at point
  926. A and an in from port 1235h at point B. You'd use the following 
  927. commands:
  928.  
  929. HP 1234 I (0,1)
  930. HP 1235 I (1,0)
  931. HC X0
  932. GH
  933.  
  934.  
  935. DETECTING HARDWARE INTERRUPTS WITH MODEL IV
  936. *******************************************
  937.  
  938. When a hardware interrupt occurs, it is preceded by two interrupt
  939. acknowledge cycles. On 80386 and higher systems, the second cycle
  940. indicates the hardware interrupt number in the low byte and can be
  941. used to selectively capture hardware interrupts, giving you a
  942. high-level overview of the interrupt sequence in your system. To set
  943. a breakpoint on this interrupt acknowledge cycle use the following
  944. command:
  945.  
  946. HM 0:0 L1 A
  947.  
  948. Note that the address of the first Int Ack cycle is 0:4 and the
  949. second, useful one is 0:0.
  950.  
  951.  
  952. TRICK COMMANDS                
  953. **************
  954.  
  955. There are some trick commands you can use in Periscope as a form of
  956. shorthand. The commands include:
  957.  
  958. G [SS:SP -- Go to the end of a near call. (You can also use the GR
  959. command.)
  960.  
  961. G {SS:SP -- Go to the end of a far call or an interrupt. (You can
  962. also use the GR command unless a hardware interrupt occurred.)
  963.  
  964. G {0:n*4 -- Go to the next invocation of interrupt n.
  965.  
  966. U {0:n*4 -- Disassemble interrupt n.
  967.  
  968. XA DS:SI -- Show 20-bit absolute address for DS:SI.
  969.  
  970. To display several different areas of memory, you can use the
  971. following alias definitions in a .def file:
  972.  
  973. \f9=^d1;
  974. \d1=d ds:di;ea f9 ^d2;
  975. \d2=d ds:si;ea f9 ^d3;
  976. \d3=d es:bp;ea f9 ^d1;
  977.  
  978. Then, successive uses of the F9 key will display each of the three
  979. memory addresses in turn. Thanks to Bruce Findlay for this tip!
  980.  
  981.  
  982. USING A DUAL VGA BOARD                
  983. **********************
  984.  
  985. We've added support for the Dual VGA and VGA/MC boards made by
  986. Colorgraphic Communications Corp. These boards let you have two VGAs
  987. in the system, using one for your program and one for Periscope.
  988.  
  989. Although both displays are showing information, only one is
  990. addressable from the system bus at any point in time. So, if you
  991. modify memory at B800:0 from Periscope, the command affects
  992. Periscope's screen, not the program's screen. If you trace an
  993. instruction that modifies memory at B800:0, the program's screen is
  994. correctly updated.
  995.  
  996. For ISA and EISA buses, the Dual VGA card is used. It has two 16-bit
  997. VGA sections on the card. To use it, note the following requirements:
  998.  
  999. - Remove any current CGA, EGA, or VGA card. If your system has a
  1000. built-in display, you'll need to disable it. 
  1001.  
  1002. - There's no need to remove any monochrome cards, but if the
  1003. monochrome card is removed, the Dual VGA will run significantly
  1004. faster, since the 16-bit access to it won't be slowed down by an
  1005. 8-bit monochrome card.
  1006.  
  1007. - When running PS.COM, specify the '/AD' option. If the Dual VGA
  1008. board is at a nonstandard address, you'll need to use the '/AD:nnn'
  1009. form to indicate the starting I/O port for the board.
  1010.  
  1011. - Periscope's display can be on either section of the Dual VGA card
  1012. (A or B), but it is assumed that only one Dual VGA card is in the
  1013. system and that the program's display is on the section not being
  1014. used by Periscope (B or A).
  1015.  
  1016. - Both displays attached to the Dual VGA card must be color displays.
  1017.  
  1018. For MicroChannel buses, the VGA/MC card is used. It comes with either
  1019. one or two VGA sections on the card. Most users will want the card
  1020. with just one VGA section. To use the VGA/MC card, note the following
  1021. requirements:
  1022.  
  1023. - The built-in VGA is always used for your program's screen and
  1024. Periscope always uses the VGA/MC for its display.
  1025.  
  1026. - When running PS.COM, specify the '/AD' option. If the Periscope
  1027. display is connected to section B (upper connector) of the VGA/MC
  1028. board, use the '/AD:B' option.
  1029.  
  1030. - There is no support for more than one VGA/MC card in the system.
  1031.  
  1032. - The display connected to the VGA/MC board must be a color display.
  1033.  
  1034. - Do not use Ctrl-Alt-Del to reboot the system while the Periscope
  1035. screen is active -- if you want to reboot from Periscope, use the QB
  1036. command. This is needed since the system VGA is turned off while
  1037. Periscope's screen is active and the BIOS does not turn it back on
  1038. during a reboot.
  1039.  
  1040. - If you're using Periscope I/MC with the VGA/MC, be sure to
  1041. configure Periscope's memory to a segment other than C000:0, since
  1042. that segment is used by the VGA/MC when it is active.
  1043.  
  1044.  
  1045. MODEL IV PODS
  1046. *************
  1047.  
  1048. There are currently seven pods available for Model IV. They are:
  1049.  
  1050. Model IV 286/386 Pod (Part #450) -- This pod includes an 18" ribbon
  1051. cable and black plastic box for the pod. It requires an 80286 or
  1052. 80386 flex cable. The maximum speed for this pod is 25MHz. Due to the
  1053. signal loading caused by the flex cable, some systems won't work
  1054. beyond 20MHz with this pod.
  1055.  
  1056. Model IV 386 Pod, Rev 1 (Part #460) -- This pod includes an 18"
  1057. ribbon cable and spacer sockets. It does not require a flex cable.
  1058. The maximum speed for this pod is 33MHz. 
  1059.  
  1060. Model IV 386 Pod, Rev 1L (Part #461) -- This pod is the same as part
  1061. #460, except for the orientation of the pod relative to the CPU.
  1062.  
  1063. Model IV 386 Pod, Rev 1B (Part #500) -- This pod is the same as part
  1064. #460, except for the orientation of the pod relative to the CPU.
  1065.  
  1066. Model IV 486 Pod, Rev 1 (Part #464) -- This pod includes an 18"
  1067. ribbon cable and spacer sockets. It does not require a flex cable.
  1068. The maximum speed for this pod is 33MHz, including DX2 chips running
  1069. at 33MHz.
  1070.  
  1071. Model IV 486 Pod, Rev 1L (Part #466) -- This pod is the same as part
  1072. #464, except for the orientation of the pod relative to the CPU.
  1073.  
  1074. Model IV 486 Pod, Rev 1R (Part #504) -- This pod is the same as part
  1075. #464, except for the orientation of the pod relative to the CPU.
  1076.  
  1077. The 286/386 pod supports both 80286 and 80386 CPUs at speeds up to
  1078. 25MHz. It requires the use of a separate Flex Cable to connect the
  1079. pod to the CPU. It works in the vast majority of systems, except
  1080. those that don't have enough room for this pod and some 386/25
  1081. systems that have reliability problems due to the Flex Cable. 
  1082.  
  1083. The 386 Pods were developed to support systems that do not have
  1084. enough physical space for the 286/386 pod or are running at higher
  1085. speeds. They attach directly to the CPU and do not use a Flex Cable.
  1086.  
  1087.  
  1088.  
  1089. MODEL IV ACCESSORIES
  1090. *******************
  1091.  
  1092. In addition to the pods described above, there are other items used 
  1093. with Model IV in various circumstances. These items include:
  1094.  
  1095. 80386SX Adapter (Part #451) -- This is used to connect a 386 Pod to
  1096. an 80386SX CPU. With this adapter, you can get full Model IV support
  1097. for an SX system.
  1098.  
  1099. 80286 PLCC Adapter Kit (20 MHz) (Part #477) -- This is used when the
  1100. 80286 CPU on the mother board is a PLCC device. The kit contains the 
  1101. adapter, a PLCC chip remover, and a 20 MHz PGA CPU chip. It has a
  1102. lower profile than Part #490 and can be used at any speed up to and
  1103. including 20 MHz.
  1104.  
  1105. 80286 LCC Adapter Kit (12 MHz) (Part #491) -- This is used when the
  1106. 80286 CPU on the mother board is a LCC (Leaderless Chip Carrier)
  1107. device. The kit contains the adapter and a 12 MHz 80286 PGA chip. To
  1108. use it, you remove the LCC chip and install the adapter head in place
  1109. of the LCC chip and then plug the 80286 Flex Cable into the PGA
  1110. socket on the adapter. The CPU chip that is included in the kit is
  1111. then plugged into the flex cable. This kit can be used in systems 
  1112. running at any speed up to and including 12 MHz.
  1113.  
  1114. 80286 Flex Cable Kit (Part #492) -- This is used with the 286/386 Pod
  1115. to connect the CPU to the pod. The kit contains the Flex Cable, a
  1116. crowbar tool, and an 80286 CPU extractor.
  1117.  
  1118. 80386 Flex Cable Kit (Part #493) -- This is used with the 286/386 Pod
  1119. to connect the CPU to the pod. The kit contains the Flex Cable, a
  1120. crowbar tool, and an 80386 CPU extractor.
  1121.  
  1122. 8-Bit Socket Extender Kit (Part #494) -- This is used to raise a PC
  1123. size board in its slot by .62 inch so that the bottom of the board
  1124. will clear obstructions on the mother board. This connector is used
  1125. for the 8-bit portion of the bus.
  1126.  
  1127. 16-Bit Socket Extender Kit (Part #495) -- This is used to raise a PC
  1128. size board in its slot by .62 inch so that the bottom of the board
  1129. will clear obstructions on the mother board. This connector is used
  1130. for the 16-bit portion of the bus.
  1131.  
  1132. Periscope Plus Board/512K (Part #152) -- This board is the same as a
  1133. Model I board, except that it contains no separate software, manual,
  1134. license, or break-out switch. It is used to keep the Model IV
  1135. software from using any memory in the first 640K.
  1136.  
  1137. Shielded Ribbon Cable (48 In) (Part #470) -- This ribbon cable is
  1138. used when active or passive remote debugging is used.
  1139.  
  1140. ISA NMI Clip (For AT Bus) (Part #471) -- This clip is used with active
  1141. remote debugging. It connects the pod to the target system so that
  1142. Periscope can stop the target (an ISA or EISA system) when a
  1143. breakpoint is reached. It is not used with passive remote debugging.
  1144.  
  1145. MC NMI Clip (For PS/2 Bus) (Part #472) -- This clip is used with
  1146. active remote debugging. It connects the pod to the target system so
  1147. that Periscope can stop the target (an MCA system) when a breakpoint
  1148. is reached.  It is not used with passive remote debugging. This clip
  1149. is usually attached directly to the microchannel bus. It can also be
  1150. clipped to pin 13 of device U30 on a Periscope I/MC board.
  1151.  
  1152.  
  1153. USING PERISCOPE WITH DESQVIEW OR QEMM
  1154. *************************************
  1155.  
  1156. To use Periscope with Quarterdeck's Desqview, you'll need to use the
  1157. following PS.COM installation options in addition to any others you
  1158. may already be using: '/V:8 /V:9 /V:10 /V:15 /V:16 /V:17'. Do not use
  1159. the '/V:1C' installation option, since this causes problems under
  1160. Desqview.
  1161.  
  1162. To use Periscope with QEMM 6.0 with Stealth mode on, you'll need to
  1163. use the /V options mentioned above. You can also use the '/V:1C'
  1164. option unless Desqview is used.
  1165.  
  1166. Please note that the use of these options makes for a less robust
  1167. debugging environment, since Periscope will then use interrupt
  1168. vectors that are no longer in ROM and are subject to corruption by a
  1169. runaway program. 
  1170.  
  1171. If you're using a Model I board with QEMM, be sure to exclude the
  1172. memory range used by the board. For example, if the board is at the 
  1173. default address of D000:0000, use 'exclude d000-d7ff' as an option
  1174. for QEMM.
  1175.  
  1176.  
  1177. SYSTEM COMPATIBILITY NOTES
  1178. ************************** 
  1179.  
  1180. If you're using a Hauppauge motherboard with a Model IV, please be
  1181. aware that RAM refresh cycles are echoed to the pins of the CPU. To
  1182. have Periscope properly handle this situation, you'll need to do
  1183. three things (see the manual for more information):
  1184.  
  1185. - Set jumper J5 on the pod to filter out the refresh cycles 
  1186. - Use the 'HC P-' control to avoid false breakpoints on the refresh cycles
  1187. - Use the '/R' option when running PS4TEST
  1188.  
  1189. Some IBM PS/2 systems such as the Model 80 can't reliably perform
  1190. serial communications at 115,200 baud. For these systems, use the
  1191. Medium speed when using Periscope's serial support.
  1192.  
  1193.  
  1194. PERISCOPE BULLETIN BOARD SYSTEM (BBS)
  1195. *************************************
  1196.  
  1197. We've established a BBS for Periscope users so that you can more
  1198. easily send or receive files and patches from us. It is available 24
  1199. hours a day at 404/888-5522 (404/875-8544 until June 25, 1993) and
  1200. supports communication speeds up to 9600 baud.  The comm settings are
  1201. 8 data bits, no parity, and 1 stop bit.
  1202.  
  1203.  
  1204. 486 INTERNAL CACHE
  1205. ******************
  1206.  
  1207. When using Model IV on a 486 system, the '/4' command toggles the
  1208. state of the cache that is an integral part of the 486 chip. When the
  1209. cache is enabled, the trace buffer display will generally be
  1210. unintelligible, since cached memory will cause no corresponding
  1211. read/write/fetch activity at the pins of the CPU where Periscope can
  1212. see it. This is not a problem on the 386, since any cache on those
  1213. systems is external to the CPU.
  1214.  
  1215. For passive remote debugging using Model IV, the PS.COM '/486'
  1216. installation option has been added. If you need to disable the cache
  1217. on a remote 486 system, use the following code:
  1218.  
  1219. cacheoff:
  1220.     mov eax,cr0
  1221.     or eax,60000000h    ; bits 30 and 29 on - disable cache
  1222.     mov cr0,eax
  1223.     wbinvd
  1224.     int 20h
  1225.  
  1226. cacheon:
  1227.     mov eax,cr0
  1228.     and eax,not 60000000h    ; bits 30 and 29 off - enable cache
  1229.     mov cr0,eax
  1230.     wbinvd
  1231.     int 20h
  1232.  
  1233. If you don't have a 486-capable assembler, the opcodes for the above are:
  1234. 66 0f 20 c0 66 0d 00 00 00 60 0f 22 c0 0f 09 cd 20 (cache off)
  1235. 66 0f 20 c0 66 25 ff ff ff 9f 0f 22 c0 0f 09 cd 20 (cache on)
  1236.  
  1237.  
  1238. NEW ADDRESS AND PHONE NUMBERS
  1239. *****************************
  1240.  
  1241. As of June 28, 1993, the new address for The Periscope Company is:
  1242.  
  1243. 1475 Peachtree Street, Suite 100
  1244. Atlanta, GA 30309
  1245.  
  1246. Our new phone numbers are:
  1247.  
  1248. Sales:         800/722-7006 (no change)
  1249. General:     404/888-5335
  1250. FAX:        404/888-5520
  1251. BBS:        404/888-5522
  1252. Tech Support:    404/888-5550
  1253.